<script setup>
import { ref, onMounted, nextTick, defineAsyncComponent } from "vue";
import * as echarts from "echarts";
// 使用 defineAsyncComponent 创建一个异步组件
const MyChart = defineAsyncComponent(() => import("@/components/mychart.vue"));
const ss = ref("");
</script>

<template>
  <main>
    <div class="cssinit" v-dyx-click-wave>
      <div>www</div>
      <button>111111</button>
      尝试点击
    </div>
    <div class="board" v-dyx-part-resize v-dyx-click-wave>
      <p>123321</p>
      <el-input
        v-model="ss"
        placeholder=""
        clearable
        style="width: 50%"
      ></el-input>
      <br />
      <hr size="1" />
      <span>6435241</span>
      <h1>649333</h1>
      <h2>{{ ss }}</h2>
      <div style="width: 50%; height: 200px">
        <MyChart></MyChart>
      </div>
    </div>
    <div style="margin-top: 20px; width: 500px;">
       <!-- data-width-base 基础宽高 500px -->
       <!-- data-width-base 最终宽高 500px * 10% = 50px -->
       <!-- v-dyx-change-wh:宽/高.是不是基础值是不是百分比='基础宽高百分比' -->
       <div
         class="radioSqu"
         v-dyx-change-wh:w="10"
         data-width-base="500"
       ></div>
       <!-- data-width-base 基础宽高 500% -->
       <!-- data-width-base 最终宽高 500% * 10% = 50% -->
       <!-- v-dyx-change-wh:宽/高.是不是基础值是不是百分比='基础宽高百分比' -->
       <div
         class="radioSqu"
         v-dyx-change-wh:w.percent="10"
         data-width-base="500"
       ></div>
     </div>
  </main>
</template>
<style lang="scss" scoped>
main {
  padding: 20px;
}
.cssinit {
  height: 150px;
  width: 100px;
  border-radius: 40%;
  background-color: rgb(38, 183, 240);
  text-align: center;
  position: relative;
}
.board {
  border: 1px solid #fff;
  overflow: hidden;
  width: 600px;
  height: 400px;
  resize: both;
}
.radioSqu {
  width: 0;
  height: 30px;
  background: linear-gradient(to right, #5e879c0f, #ff0);
  border-right: 5px solid #94c1d7;
  transition: all 0.5s;
}
</style>
